using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using System;

namespace KFGame.Modes
{
    

    [System.Serializable]
    public class KFSeralPortEventMode
    {
        /// <summary>
        /// 分组名
        /// </summary>
        public string modeName;

        /// <summary>
        /// 启用
        /// </summary>
        [SerializeField]
        [Tooltip("是否生效,作用于读")]
        public bool enter = true;
        /// <summary>
        /// 名字
        /// </summary>
        [SerializeField]
        [Tooltip("记录名称")]
        public string name;


        /// <summary>
        /// com 接口名字
        /// </summary>
        [SerializeField]
        [Tooltip("com 接口配置中的名字")]
        public string com = "com1";

        [SerializeField]
        [Tooltip("标签")]
        public string tag = "1";

        [SerializeField]
        [Tooltip("事件类型 读或写")]
        public string type = "read";

        [SerializeField]
        [Tooltip("事件计算验证方法")]
        public string dataType = "read";

        [SerializeField]
        [Tooltip("事件数据所在位置")]
        public int dataIndex = 1;
        [SerializeField]
        [Tooltip("事件数据的长度")]
        public int dataLength = 1;
        [SerializeField]
        [Tooltip("事件对应数据位校验数")]
        public string checkdata = "01";
        [SerializeField]
        [Tooltip("发送数参考模板")]
        public string templateData = "";
        [SerializeField]
        [Tooltip("发送持续次数")]
        public int sendnumber = 1;
          [SerializeField]
        [Tooltip("发送持续时间")]

        public double sendtime =0.0f;
        [SerializeField]
        [Tooltip("引入回调事件计数")]
        public string fiterName;
        [SerializeField]
        [Tooltip("是否在停止时,发送别一个事件")]
        public bool isEnd = false;
        [SerializeField]
        [Tooltip("停止事件,需要发送数时对应的事件")]
        public string EndDataName;


        /// <summary>
        /// 被注
        /// </summary>
        [SerializeField]
        [Tooltip("写下备注为了更好的理解")]
        public string des;

    }
}